<?php if (!defined('THINK_PATH')) exit();?><!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <title>天盈 CRM 管理系统——登录</title>
    <link rel="stylesheet" href="/Public/frame/layui/css/layui.css">
    <link rel="stylesheet" href="/Public/frame/static/css/style.css">
    <script type="text/javascript" charset="utf-8" src="/Public/hawk/js/jquery-1.8.0.min.js"></script>
</head>
<body class="login-body body" style="background:rgba(0,0,0,.3);background:url('/Public/hawk/images/bg.png')">

<div class="login-box" style="background:rgba(0,0,0,.3);">
    <form class="layui-form layui-form-pane" method="post" action="/index.php/Hawk/Login/login">
        <div class="layui-form-item">
            <h3>天盈 CRM 管理系统</h3>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">账号：</label>

            <div class="layui-input-inline">
                <input type="text" name="username" class="layui-input" lay-verify="account" placeholder="账号"
                       autocomplete="on" maxlength="20"/>
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">密码：</label>

            <div class="layui-input-inline">
                <input type="password" name="password" class="layui-input" lay-verify="password" placeholder="密码"
                       maxlength="20"/>
            </div>
        </div>
        <div class="layui-form-item">
            <label class="layui-form-label">验证码：</label>

            <div class="layui-input-inline">
                <input type="text" name="captcha" class="layui-input" lay-verify="code" placeholder="验证码" maxlength="4" style="width:50%;display:inline-block;" />
                <img src="<?php echo U('Login/Vcode')?>" onclick="this.src='<?php echo U('Login/Vcode')?>#'+Math.random;" width="87" height="38" style="margin-left:1%;"/> 
            </div>
        </div>
        <div class="layui-form-item">
            <button type="reset" class="layui-btn layui-btn-danger btn-reset">重置</button>
            <button type="submit" class="layui-btn btn-submit" lay-submit="" lay-filter="sub">立即登录</button>
        </div>
    </form>
</div>
<script type="text/javascript" charset="utf-8" src="/Public/hawk/js/jquery-1.8.0.min.js"></script>
<script type="text/javascript" src="/Public/frame/layui/layui.js"></script>
<script type="text/javascript">
    // layui.use(['form', 'layer'], function () {

    //     // 操作对象
    //     var form = layui.form
    //             , layer = layui.layer
    //             , $ = layui.jquery;

    //     // 验证
    //     form.verify({
    //         account: function (value) {
    //             if (value == "") {
    //                 return "请输入用户名";
    //             }
    //         },
    //         password: function (value) {
    //             if (value == "") {
    //                 return "请输入密码";
    //             }
    //         },
    //         code: function (value) {
    //             if (value == "") {
    //                 return "请输入验证码";
    //             }
    //         }
    //     });

    //     // 提交监听
    //     form.on('submit(sub)', function (data) {
    //         layer.alert(JSON.stringify(data.field), {
    //             title: '最终的提交信息'
    //         });
    //         return false;
    //     });

    //     // you code ...
    // })

</script>
</body>
</html>